<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><link rel="stylesheet" type="text/css" href="style.css" /><script type="text/javascript" src="highlight.js"></script></head><body><pre><span id="local-6989586621679091301"><span id="local-6989586621679091302"></span></span><span class="hs-keyword">module</span><span> </span><span class="hs-identifier">System.Console.Haskeline.Key</span><span class="hs-special">(</span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier">Key</span></a></span><span class="hs-special">(</span><span class="hs-glyph">..</span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-2"></span><span>            </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Modifier"><span class="hs-identifier">Modifier</span></a></span><span class="hs-special">(</span><span class="hs-glyph">..</span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-3"></span><span>            </span><span class="annot"><a href="System.Console.Haskeline.Key.html#BaseKey"><span class="hs-identifier">BaseKey</span></a></span><span class="hs-special">(</span><span class="hs-glyph">..</span><span class="hs-special">)</span><span class="hs-special">,</span><span>
</span><span id="line-4"></span><span>            </span><span class="annot"><a href="System.Console.Haskeline.Key.html#noModifier"><span class="hs-identifier">noModifier</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-5"></span><span>            </span><span class="annot"><a href="System.Console.Haskeline.Key.html#simpleKey"><span class="hs-identifier">simpleKey</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-6"></span><span>            </span><span class="annot"><a href="System.Console.Haskeline.Key.html#simpleChar"><span class="hs-identifier">simpleChar</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-7"></span><span>            </span><span class="annot"><a href="System.Console.Haskeline.Key.html#metaChar"><span class="hs-identifier">metaChar</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-8"></span><span>            </span><span class="annot"><a href="System.Console.Haskeline.Key.html#ctrlChar"><span class="hs-identifier">ctrlChar</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-9"></span><span>            </span><span class="annot"><a href="System.Console.Haskeline.Key.html#metaKey"><span class="hs-identifier">metaKey</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-10"></span><span>            </span><span class="annot"><a href="System.Console.Haskeline.Key.html#ctrlKey"><span class="hs-identifier">ctrlKey</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-11"></span><span>            </span><span class="annot"><a href="System.Console.Haskeline.Key.html#parseKey"><span class="hs-identifier">parseKey</span></a></span><span>
</span><span id="line-12"></span><span>            </span><span class="hs-special">)</span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-13"></span><span>
</span><span id="line-14"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/Data.Bits.html#"><span class="hs-identifier">Data.Bits</span></a></span><span>
</span><span id="line-15"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/Data.Char.html#"><span class="hs-identifier">Data.Char</span></a></span><span>
</span><span id="line-16"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/Data.Maybe.html#"><span class="hs-identifier">Data.Maybe</span></a></span><span>
</span><span id="line-17"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/Data.List.html#"><span class="hs-identifier">Data.List</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/Data.OldList.html#intercalate"><span class="hs-identifier">intercalate</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-18"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/Control.Monad.html#"><span class="hs-identifier">Control.Monad</span></a></span><span>
</span><span id="line-19"></span><span>
</span><span id="line-20"></span><span class="hs-keyword">data</span><span> </span><span id="Key"><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-var">Key</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span id="Key"><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-var">Key</span></a></span></span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Modifier"><span class="hs-identifier hs-type">Modifier</span></a></span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#BaseKey"><span class="hs-identifier hs-type">BaseKey</span></a></span><span>
</span><span id="line-21"></span><span>            </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621679091263"><span id="local-6989586621679091267"><span class="annot"><span class="annottext">Key -&gt; Key -&gt; Bool
(Key -&gt; Key -&gt; Bool) -&gt; (Key -&gt; Key -&gt; Bool) -&gt; Eq Key
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: Key -&gt; Key -&gt; Bool
$c/= :: Key -&gt; Key -&gt; Bool
== :: Key -&gt; Key -&gt; Bool
$c== :: Key -&gt; Key -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">,</span><span id="local-6989586621679091239"><span id="local-6989586621679091241"><span id="local-6989586621679091244"><span id="local-6989586621679091247"><span id="local-6989586621679091250"><span id="local-6989586621679091254"><span id="local-6989586621679091258"><span class="annot"><span class="annottext">Eq Key
Eq Key
-&gt; (Key -&gt; Key -&gt; Ordering)
-&gt; (Key -&gt; Key -&gt; Bool)
-&gt; (Key -&gt; Key -&gt; Bool)
-&gt; (Key -&gt; Key -&gt; Bool)
-&gt; (Key -&gt; Key -&gt; Bool)
-&gt; (Key -&gt; Key -&gt; Key)
-&gt; (Key -&gt; Key -&gt; Key)
-&gt; Ord Key
Key -&gt; Key -&gt; Bool
Key -&gt; Key -&gt; Ordering
Key -&gt; Key -&gt; Key
forall a.
Eq a
-&gt; (a -&gt; a -&gt; Ordering)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; a)
-&gt; (a -&gt; a -&gt; a)
-&gt; Ord a
min :: Key -&gt; Key -&gt; Key
$cmin :: Key -&gt; Key -&gt; Key
max :: Key -&gt; Key -&gt; Key
$cmax :: Key -&gt; Key -&gt; Key
&gt;= :: Key -&gt; Key -&gt; Bool
$c&gt;= :: Key -&gt; Key -&gt; Bool
&gt; :: Key -&gt; Key -&gt; Bool
$c&gt; :: Key -&gt; Key -&gt; Bool
&lt;= :: Key -&gt; Key -&gt; Bool
$c&lt;= :: Key -&gt; Key -&gt; Bool
&lt; :: Key -&gt; Key -&gt; Bool
$c&lt; :: Key -&gt; Key -&gt; Bool
compare :: Key -&gt; Key -&gt; Ordering
$ccompare :: Key -&gt; Key -&gt; Ordering
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var">Ord</span></span></span></span></span></span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-22"></span><span>
</span><span id="line-23"></span><span class="hs-keyword">instance</span><span> </span><span id="local-6989586621679091233"><span id="local-6989586621679091236"><span class="annot"><a href="../../base/src/GHC.Show.html#Show"><span class="hs-identifier hs-type">Show</span></a></span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span></span></span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-24"></span><span>    </span><span id="local-6989586621679091227"><span class="annot"><span class="annottext">show :: Key -&gt; [Char]
</span><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var hs-var hs-var hs-var">show</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span> </span><span id="local-6989586621679091225"><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091225"><span class="hs-identifier hs-var">modifier</span></a></span></span><span> </span><span id="local-6989586621679091224"><span class="annot"><span class="annottext">BaseKey
</span><a href="#local-6989586621679091224"><span class="hs-identifier hs-var">base</span></a></span></span><span class="hs-special">)</span><span>
</span><span id="line-25"></span><span>        </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091225"><span class="hs-identifier hs-var">modifier</span></a></span><span> </span><span class="annot"><span class="annottext">Modifier -&gt; Modifier -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="System.Console.Haskeline.Key.html#noModifier"><span class="hs-identifier hs-var">noModifier</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">BaseKey -&gt; [Char]
forall a. Show a =&gt; a -&gt; [Char]
</span><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="#local-6989586621679091224"><span class="hs-identifier hs-var">base</span></a></span><span>
</span><span id="line-26"></span><span>        </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="../../base/src/GHC.Base.html#otherwise"><span class="hs-identifier hs-var">otherwise</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Modifier -&gt; [Char]
forall a. Show a =&gt; a -&gt; [Char]
</span><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091225"><span class="hs-identifier hs-var">modifier</span></a></span><span> </span><span class="annot"><span class="annottext">[Char] -&gt; ShowS
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;-&quot;</span></span><span> </span><span class="annot"><span class="annottext">[Char] -&gt; ShowS
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey -&gt; [Char]
forall a. Show a =&gt; a -&gt; [Char]
</span><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="#local-6989586621679091224"><span class="hs-identifier hs-var">base</span></a></span><span>
</span><span id="line-27"></span><span>
</span><span id="line-28"></span><span class="hs-keyword">data</span><span> </span><span id="Modifier"><span class="annot"><a href="System.Console.Haskeline.Key.html#Modifier"><span class="hs-identifier hs-var">Modifier</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span id="Modifier"><span class="annot"><a href="System.Console.Haskeline.Key.html#Modifier"><span class="hs-identifier hs-var">Modifier</span></a></span></span><span> </span><span class="hs-special">{</span><span id="hasControl"><span class="annot"><span class="annottext">Modifier -&gt; Bool
</span><a href="System.Console.Haskeline.Key.html#hasControl"><span class="hs-identifier hs-var hs-var">hasControl</span></a></span></span><span class="hs-special">,</span><span> </span><span id="hasMeta"><span class="annot"><span class="annottext">Modifier -&gt; Bool
</span><a href="System.Console.Haskeline.Key.html#hasMeta"><span class="hs-identifier hs-var hs-var">hasMeta</span></a></span></span><span class="hs-special">,</span><span> </span><span id="hasShift"><span class="annot"><span class="annottext">Modifier -&gt; Bool
</span><a href="System.Console.Haskeline.Key.html#hasShift"><span class="hs-identifier hs-var hs-var">hasShift</span></a></span></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span class="hs-special">}</span><span>
</span><span id="line-29"></span><span>            </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621679091212"><span id="local-6989586621679091218"><span class="annot"><span class="annottext">Modifier -&gt; Modifier -&gt; Bool
(Modifier -&gt; Modifier -&gt; Bool)
-&gt; (Modifier -&gt; Modifier -&gt; Bool) -&gt; Eq Modifier
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: Modifier -&gt; Modifier -&gt; Bool
$c/= :: Modifier -&gt; Modifier -&gt; Bool
== :: Modifier -&gt; Modifier -&gt; Bool
$c== :: Modifier -&gt; Modifier -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">,</span><span id="local-6989586621679091186"><span id="local-6989586621679091188"><span id="local-6989586621679091191"><span id="local-6989586621679091194"><span id="local-6989586621679091197"><span id="local-6989586621679091202"><span id="local-6989586621679091208"><span class="annot"><span class="annottext">Eq Modifier
Eq Modifier
-&gt; (Modifier -&gt; Modifier -&gt; Ordering)
-&gt; (Modifier -&gt; Modifier -&gt; Bool)
-&gt; (Modifier -&gt; Modifier -&gt; Bool)
-&gt; (Modifier -&gt; Modifier -&gt; Bool)
-&gt; (Modifier -&gt; Modifier -&gt; Bool)
-&gt; (Modifier -&gt; Modifier -&gt; Modifier)
-&gt; (Modifier -&gt; Modifier -&gt; Modifier)
-&gt; Ord Modifier
Modifier -&gt; Modifier -&gt; Bool
Modifier -&gt; Modifier -&gt; Ordering
Modifier -&gt; Modifier -&gt; Modifier
forall a.
Eq a
-&gt; (a -&gt; a -&gt; Ordering)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; a)
-&gt; (a -&gt; a -&gt; a)
-&gt; Ord a
min :: Modifier -&gt; Modifier -&gt; Modifier
$cmin :: Modifier -&gt; Modifier -&gt; Modifier
max :: Modifier -&gt; Modifier -&gt; Modifier
$cmax :: Modifier -&gt; Modifier -&gt; Modifier
&gt;= :: Modifier -&gt; Modifier -&gt; Bool
$c&gt;= :: Modifier -&gt; Modifier -&gt; Bool
&gt; :: Modifier -&gt; Modifier -&gt; Bool
$c&gt; :: Modifier -&gt; Modifier -&gt; Bool
&lt;= :: Modifier -&gt; Modifier -&gt; Bool
$c&lt;= :: Modifier -&gt; Modifier -&gt; Bool
&lt; :: Modifier -&gt; Modifier -&gt; Bool
$c&lt; :: Modifier -&gt; Modifier -&gt; Bool
compare :: Modifier -&gt; Modifier -&gt; Ordering
$ccompare :: Modifier -&gt; Modifier -&gt; Ordering
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var">Ord</span></span></span></span></span></span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-30"></span><span>
</span><span id="line-31"></span><span class="hs-keyword">instance</span><span> </span><span id="local-6989586621679091181"><span id="local-6989586621679091184"><span class="annot"><a href="../../base/src/GHC.Show.html#Show"><span class="hs-identifier hs-type">Show</span></a></span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Modifier"><span class="hs-identifier hs-type">Modifier</span></a></span></span></span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-32"></span><span>    </span><span id="local-6989586621679091180"><span class="annot"><span class="annottext">show :: Modifier -&gt; [Char]
</span><a href="#local-6989586621679091180"><span class="hs-identifier hs-var hs-var hs-var hs-var">show</span></a></span></span><span> </span><span id="local-6989586621679091179"><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091179"><span class="hs-identifier hs-var">m</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char] -&gt; [[Char]] -&gt; [Char]
forall a. [a] -&gt; [[a]] -&gt; [a]
</span><a href="../../base/src/Data.OldList.html#intercalate"><span class="hs-identifier hs-var">intercalate</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;-&quot;</span></span><span>
</span><span id="line-33"></span><span>            </span><span class="annot"><span class="annottext">([[Char]] -&gt; [Char]) -&gt; [[Char]] -&gt; [Char]
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">[Maybe [Char]] -&gt; [[Char]]
forall a. [Maybe a] -&gt; [a]
</span><a href="../../base/src/Data.Maybe.html#catMaybes"><span class="hs-identifier hs-var">catMaybes</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">(Modifier -&gt; Bool) -&gt; [Char] -&gt; Maybe [Char]
forall {a}. (Modifier -&gt; Bool) -&gt; a -&gt; Maybe a
</span><a href="#local-6989586621679091177"><span class="hs-identifier hs-var">maybeUse</span></a></span><span> </span><span class="annot"><span class="annottext">Modifier -&gt; Bool
</span><a href="System.Console.Haskeline.Key.html#hasControl"><span class="hs-identifier hs-var hs-var">hasControl</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;ctrl&quot;</span></span><span>
</span><span id="line-34"></span><span>                        </span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">(Modifier -&gt; Bool) -&gt; [Char] -&gt; Maybe [Char]
forall {a}. (Modifier -&gt; Bool) -&gt; a -&gt; Maybe a
</span><a href="#local-6989586621679091177"><span class="hs-identifier hs-var">maybeUse</span></a></span><span> </span><span class="annot"><span class="annottext">Modifier -&gt; Bool
</span><a href="System.Console.Haskeline.Key.html#hasMeta"><span class="hs-identifier hs-var hs-var">hasMeta</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;meta&quot;</span></span><span>
</span><span id="line-35"></span><span>                        </span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">(Modifier -&gt; Bool) -&gt; [Char] -&gt; Maybe [Char]
forall {a}. (Modifier -&gt; Bool) -&gt; a -&gt; Maybe a
</span><a href="#local-6989586621679091177"><span class="hs-identifier hs-var">maybeUse</span></a></span><span> </span><span class="annot"><span class="annottext">Modifier -&gt; Bool
</span><a href="System.Console.Haskeline.Key.html#hasShift"><span class="hs-identifier hs-var hs-var">hasShift</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;shift&quot;</span></span><span>
</span><span id="line-36"></span><span>                        </span><span class="hs-special">]</span><span>
</span><span id="line-37"></span><span>        </span><span class="hs-keyword">where</span><span>
</span><span id="line-38"></span><span>            </span><span id="local-6989586621679091177"><span class="annot"><span class="annottext">maybeUse :: (Modifier -&gt; Bool) -&gt; a -&gt; Maybe a
</span><a href="#local-6989586621679091177"><span class="hs-identifier hs-var hs-var">maybeUse</span></a></span></span><span> </span><span id="local-6989586621679091176"><span class="annot"><span class="annottext">Modifier -&gt; Bool
</span><a href="#local-6989586621679091176"><span class="hs-identifier hs-var">f</span></a></span></span><span> </span><span id="local-6989586621679091175"><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621679091175"><span class="hs-identifier hs-var">str</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">if</span><span> </span><span class="annot"><span class="annottext">Modifier -&gt; Bool
</span><a href="#local-6989586621679091176"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091179"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="hs-keyword">then</span><span> </span><span class="annot"><span class="annottext">a -&gt; Maybe a
forall a. a -&gt; Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-var">Just</span></a></span><span> </span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621679091175"><span class="hs-identifier hs-var">str</span></a></span><span> </span><span class="hs-keyword">else</span><span> </span><span class="annot"><span class="annottext">Maybe a
forall a. Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span>
</span><span id="line-39"></span><span>
</span><span id="line-40"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#noModifier"><span class="hs-identifier hs-type">noModifier</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Modifier"><span class="hs-identifier hs-type">Modifier</span></a></span><span>
</span><span id="line-41"></span><span id="noModifier"><span class="annot"><span class="annottext">noModifier :: Modifier
</span><a href="System.Console.Haskeline.Key.html#noModifier"><span class="hs-identifier hs-var hs-var">noModifier</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool -&gt; Modifier
</span><a href="System.Console.Haskeline.Key.html#Modifier"><span class="hs-identifier hs-var">Modifier</span></a></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-42"></span><span>
</span><span id="line-43"></span><span class="hs-comment">-- Note: a few of these aren't really keys (e.g., KillLine),</span><span>
</span><span id="line-44"></span><span class="hs-comment">-- but they provide useful enough binding points to include.</span><span>
</span><span id="line-45"></span><span class="hs-keyword">data</span><span> </span><span id="BaseKey"><span class="annot"><a href="System.Console.Haskeline.Key.html#BaseKey"><span class="hs-identifier hs-var">BaseKey</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span id="KeyChar"><span class="annot"><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-var">KeyChar</span></a></span></span><span> </span><span class="annot"><span class="hs-identifier hs-type">Char</span></span><span>
</span><span id="line-46"></span><span>             </span><span class="hs-glyph">|</span><span> </span><span id="FunKey"><span class="annot"><a href="System.Console.Haskeline.Key.html#FunKey"><span class="hs-identifier hs-var">FunKey</span></a></span></span><span> </span><span class="annot"><span class="hs-identifier hs-type">Int</span></span><span>
</span><span id="line-47"></span><span>             </span><span class="hs-glyph">|</span><span> </span><span id="LeftKey"><span class="annot"><a href="System.Console.Haskeline.Key.html#LeftKey"><span class="hs-identifier hs-var">LeftKey</span></a></span></span><span> </span><span class="hs-glyph">|</span><span> </span><span id="RightKey"><span class="annot"><a href="System.Console.Haskeline.Key.html#RightKey"><span class="hs-identifier hs-var">RightKey</span></a></span></span><span> </span><span class="hs-glyph">|</span><span> </span><span id="DownKey"><span class="annot"><a href="System.Console.Haskeline.Key.html#DownKey"><span class="hs-identifier hs-var">DownKey</span></a></span></span><span> </span><span class="hs-glyph">|</span><span> </span><span id="UpKey"><span class="annot"><a href="System.Console.Haskeline.Key.html#UpKey"><span class="hs-identifier hs-var">UpKey</span></a></span></span><span>
</span><span id="line-48"></span><span>             </span><span class="hs-glyph">|</span><span> </span><span id="KillLine"><span class="annot"><a href="System.Console.Haskeline.Key.html#KillLine"><span class="hs-identifier hs-var">KillLine</span></a></span></span><span> </span><span class="hs-glyph">|</span><span> </span><span id="Home"><span class="annot"><a href="System.Console.Haskeline.Key.html#Home"><span class="hs-identifier hs-var">Home</span></a></span></span><span> </span><span class="hs-glyph">|</span><span> </span><span id="End"><span class="annot"><a href="System.Console.Haskeline.Key.html#End"><span class="hs-identifier hs-var">End</span></a></span></span><span> </span><span class="hs-glyph">|</span><span> </span><span id="PageDown"><span class="annot"><a href="System.Console.Haskeline.Key.html#PageDown"><span class="hs-identifier hs-var">PageDown</span></a></span></span><span> </span><span class="hs-glyph">|</span><span> </span><span id="PageUp"><span class="annot"><a href="System.Console.Haskeline.Key.html#PageUp"><span class="hs-identifier hs-var">PageUp</span></a></span></span><span>
</span><span id="line-49"></span><span>             </span><span class="hs-glyph">|</span><span> </span><span id="Backspace"><span class="annot"><a href="System.Console.Haskeline.Key.html#Backspace"><span class="hs-identifier hs-var">Backspace</span></a></span></span><span> </span><span class="hs-glyph">|</span><span> </span><span id="Delete"><span class="annot"><a href="System.Console.Haskeline.Key.html#Delete"><span class="hs-identifier hs-var">Delete</span></a></span></span><span>
</span><span id="line-50"></span><span>             </span><span class="hs-glyph">|</span><span> </span><span id="SearchReverse"><span class="annot"><a href="System.Console.Haskeline.Key.html#SearchReverse"><span class="hs-identifier hs-var">SearchReverse</span></a></span></span><span> </span><span class="hs-glyph">|</span><span> </span><span id="SearchForward"><span class="annot"><a href="System.Console.Haskeline.Key.html#SearchForward"><span class="hs-identifier hs-var">SearchForward</span></a></span></span><span>
</span><span id="line-51"></span><span>            </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621679091153"><span id="local-6989586621679091158"><span class="annot"><span class="annottext">BaseKey -&gt; BaseKey -&gt; Bool
(BaseKey -&gt; BaseKey -&gt; Bool)
-&gt; (BaseKey -&gt; BaseKey -&gt; Bool) -&gt; Eq BaseKey
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: BaseKey -&gt; BaseKey -&gt; Bool
$c/= :: BaseKey -&gt; BaseKey -&gt; Bool
== :: BaseKey -&gt; BaseKey -&gt; Bool
$c== :: BaseKey -&gt; BaseKey -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621679091133"><span id="local-6989586621679091135"><span id="local-6989586621679091137"><span id="local-6989586621679091139"><span id="local-6989586621679091141"><span id="local-6989586621679091143"><span id="local-6989586621679091149"><span class="annot"><span class="annottext">Eq BaseKey
Eq BaseKey
-&gt; (BaseKey -&gt; BaseKey -&gt; Ordering)
-&gt; (BaseKey -&gt; BaseKey -&gt; Bool)
-&gt; (BaseKey -&gt; BaseKey -&gt; Bool)
-&gt; (BaseKey -&gt; BaseKey -&gt; Bool)
-&gt; (BaseKey -&gt; BaseKey -&gt; Bool)
-&gt; (BaseKey -&gt; BaseKey -&gt; BaseKey)
-&gt; (BaseKey -&gt; BaseKey -&gt; BaseKey)
-&gt; Ord BaseKey
BaseKey -&gt; BaseKey -&gt; Bool
BaseKey -&gt; BaseKey -&gt; Ordering
BaseKey -&gt; BaseKey -&gt; BaseKey
forall a.
Eq a
-&gt; (a -&gt; a -&gt; Ordering)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; Bool)
-&gt; (a -&gt; a -&gt; a)
-&gt; (a -&gt; a -&gt; a)
-&gt; Ord a
min :: BaseKey -&gt; BaseKey -&gt; BaseKey
$cmin :: BaseKey -&gt; BaseKey -&gt; BaseKey
max :: BaseKey -&gt; BaseKey -&gt; BaseKey
$cmax :: BaseKey -&gt; BaseKey -&gt; BaseKey
&gt;= :: BaseKey -&gt; BaseKey -&gt; Bool
$c&gt;= :: BaseKey -&gt; BaseKey -&gt; Bool
&gt; :: BaseKey -&gt; BaseKey -&gt; Bool
$c&gt; :: BaseKey -&gt; BaseKey -&gt; Bool
&lt;= :: BaseKey -&gt; BaseKey -&gt; Bool
$c&lt;= :: BaseKey -&gt; BaseKey -&gt; Bool
&lt; :: BaseKey -&gt; BaseKey -&gt; Bool
$c&lt; :: BaseKey -&gt; BaseKey -&gt; Bool
compare :: BaseKey -&gt; BaseKey -&gt; Ordering
$ccompare :: BaseKey -&gt; BaseKey -&gt; Ordering
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var">Ord</span></span></span></span></span></span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-52"></span><span>
</span><span id="line-53"></span><span class="hs-keyword">instance</span><span> </span><span id="local-6989586621679091128"><span id="local-6989586621679091131"><span class="annot"><a href="../../base/src/GHC.Show.html#Show"><span class="hs-identifier hs-type">Show</span></a></span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#BaseKey"><span class="hs-identifier hs-type">BaseKey</span></a></span></span></span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-54"></span><span>    </span><span id="local-6989586621679091123"><span class="annot"><span class="annottext">show :: BaseKey -&gt; [Char]
</span><a href="#local-6989586621679091123"><span class="hs-identifier hs-var hs-var hs-var hs-var">show</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-type">KeyChar</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'\n'</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;Return&quot;</span></span><span>
</span><span id="line-55"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-type">KeyChar</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'\t'</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;Tab&quot;</span></span><span>
</span><span id="line-56"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-type">KeyChar</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'\ESC'</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;Esc&quot;</span></span><span>
</span><span id="line-57"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-type">KeyChar</span></a></span><span> </span><span id="local-6989586621679091122"><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091122"><span class="hs-identifier hs-var">c</span></a></span></span><span class="hs-special">)</span><span>
</span><span id="line-58"></span><span>        </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Char -&gt; Bool
</span><a href="../../base/src/GHC.Unicode.html#isPrint"><span class="hs-identifier hs-var">isPrint</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091122"><span class="hs-identifier hs-var">c</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091122"><span class="hs-identifier hs-var">c</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-59"></span><span>        </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Char -&gt; Bool
</span><a href="../../base/src/GHC.Unicode.html#isPrint"><span class="hs-identifier hs-var">isPrint</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091120"><span class="hs-identifier hs-var">unCtrld</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;ctrl-&quot;</span></span><span> </span><span class="annot"><span class="annottext">[Char] -&gt; ShowS
forall a. [a] -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.Base.html#%2B%2B"><span class="hs-operator hs-var">++</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091120"><span class="hs-identifier hs-var">unCtrld</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-60"></span><span>        </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="../../base/src/GHC.Base.html#otherwise"><span class="hs-identifier hs-var">otherwise</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Char -&gt; [Char]
forall a. Show a =&gt; a -&gt; [Char]
</span><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091122"><span class="hs-identifier hs-var">c</span></a></span><span>
</span><span id="line-61"></span><span>      </span><span class="hs-keyword">where</span><span>
</span><span id="line-62"></span><span>        </span><span id="local-6989586621679091120"><span class="annot"><span class="annottext">unCtrld :: Char
</span><a href="#local-6989586621679091120"><span class="hs-identifier hs-var hs-var">unCtrld</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; Char
forall a. Enum a =&gt; Int -&gt; a
</span><a href="../../base/src/GHC.Enum.html#toEnum"><span class="hs-identifier hs-var">toEnum</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Char -&gt; Int
forall a. Enum a =&gt; a -&gt; Int
</span><a href="../../base/src/GHC.Enum.html#fromEnum"><span class="hs-identifier hs-var">fromEnum</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091122"><span class="hs-identifier hs-var">c</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Int
forall a. Bits a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/Data.Bits.html#.%7C."><span class="hs-operator hs-var">.|.</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="System.Console.Haskeline.Key.html#ctrlBits"><span class="hs-identifier hs-var">ctrlBits</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-63"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="System.Console.Haskeline.Key.html#FunKey"><span class="hs-identifier hs-type">FunKey</span></a></span><span> </span><span id="local-6989586621679091112"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621679091112"><span class="hs-identifier hs-var">n</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'f'</span></span><span> </span><span class="annot"><span class="annottext">Char -&gt; ShowS
forall a. a -&gt; [a] -&gt; [a]
</span><span class="hs-glyph hs-var">:</span></span><span> </span><span class="annot"><span class="annottext">Int -&gt; [Char]
forall a. Show a =&gt; a -&gt; [Char]
</span><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621679091112"><span class="hs-identifier hs-var">n</span></a></span><span>
</span><span id="line-64"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#LeftKey"><span class="hs-identifier hs-var">LeftKey</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;Left&quot;</span></span><span>
</span><span id="line-65"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#RightKey"><span class="hs-identifier hs-var">RightKey</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;Right&quot;</span></span><span>
</span><span id="line-66"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#DownKey"><span class="hs-identifier hs-var">DownKey</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;Down&quot;</span></span><span>
</span><span id="line-67"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#UpKey"><span class="hs-identifier hs-var">UpKey</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;Up&quot;</span></span><span>
</span><span id="line-68"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#KillLine"><span class="hs-identifier hs-var">KillLine</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;KillLine&quot;</span></span><span>
</span><span id="line-69"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#Home"><span class="hs-identifier hs-var">Home</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;Home&quot;</span></span><span>
</span><span id="line-70"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#End"><span class="hs-identifier hs-var">End</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;End&quot;</span></span><span>
</span><span id="line-71"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#PageDown"><span class="hs-identifier hs-var">PageDown</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;PageDown&quot;</span></span><span>
</span><span id="line-72"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#PageUp"><span class="hs-identifier hs-var">PageUp</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;PageUp&quot;</span></span><span>
</span><span id="line-73"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#Backspace"><span class="hs-identifier hs-var">Backspace</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;Backspace&quot;</span></span><span>
</span><span id="line-74"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#Delete"><span class="hs-identifier hs-var">Delete</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;Delete&quot;</span></span><span>
</span><span id="line-75"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#SearchReverse"><span class="hs-identifier hs-var">SearchReverse</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;SearchReverse&quot;</span></span><span>
</span><span id="line-76"></span><span>    </span><span class="annot"><a href="../../base/src/GHC.Show.html#show"><span class="hs-identifier hs-var">show</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#SearchForward"><span class="hs-identifier hs-var">SearchForward</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;SearchForward&quot;</span></span><span>
</span><span id="line-77"></span><span>
</span><span id="line-78"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#simpleKey"><span class="hs-identifier hs-type">simpleKey</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#BaseKey"><span class="hs-identifier hs-type">BaseKey</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span>
</span><span id="line-79"></span><span id="simpleKey"><span class="annot"><span class="annottext">simpleKey :: BaseKey -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#simpleKey"><span class="hs-identifier hs-var hs-var">simpleKey</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Modifier -&gt; BaseKey -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-var">Key</span></a></span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="System.Console.Haskeline.Key.html#noModifier"><span class="hs-identifier hs-var">noModifier</span></a></span><span>
</span><span id="line-80"></span><span>
</span><span id="line-81"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#metaKey"><span class="hs-identifier hs-type">metaKey</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span>
</span><span id="line-82"></span><span id="metaKey"><span class="annot"><span class="annottext">metaKey :: Key -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#metaKey"><span class="hs-identifier hs-var hs-var">metaKey</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span> </span><span id="local-6989586621679091111"><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091111"><span class="hs-identifier hs-var">m</span></a></span></span><span> </span><span id="local-6989586621679091110"><span class="annot"><span class="annottext">BaseKey
</span><a href="#local-6989586621679091110"><span class="hs-identifier hs-var">bc</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Modifier -&gt; BaseKey -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-var">Key</span></a></span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091111"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="hs-special">{</span><span class="annot"><span class="annottext">hasMeta :: Bool
</span><a href="System.Console.Haskeline.Key.html#hasMeta"><span class="hs-identifier hs-var">hasMeta</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span class="hs-special">}</span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="#local-6989586621679091110"><span class="hs-identifier hs-var">bc</span></a></span><span>
</span><span id="line-83"></span><span>
</span><span id="line-84"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#ctrlKey"><span class="hs-identifier hs-type">ctrlKey</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span>
</span><span id="line-85"></span><span id="ctrlKey"><span class="annot"><span class="annottext">ctrlKey :: Key -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#ctrlKey"><span class="hs-identifier hs-var hs-var">ctrlKey</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span> </span><span id="local-6989586621679091109"><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091109"><span class="hs-identifier hs-var">m</span></a></span></span><span> </span><span id="local-6989586621679091108"><span class="annot"><span class="annottext">BaseKey
</span><a href="#local-6989586621679091108"><span class="hs-identifier hs-var">bc</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Modifier -&gt; BaseKey -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-var">Key</span></a></span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091109"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="hs-special">{</span><span class="annot"><span class="annottext">hasControl :: Bool
</span><a href="System.Console.Haskeline.Key.html#hasControl"><span class="hs-identifier hs-var">hasControl</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span class="hs-special">}</span><span> </span><span class="annot"><span class="annottext">BaseKey
</span><a href="#local-6989586621679091108"><span class="hs-identifier hs-var">bc</span></a></span><span>
</span><span id="line-86"></span><span>
</span><span id="line-87"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#simpleChar"><span class="hs-identifier hs-type">simpleChar</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#metaChar"><span class="hs-identifier hs-type">metaChar</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#ctrlChar"><span class="hs-identifier hs-type">ctrlChar</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Char</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span>
</span><span id="line-88"></span><span id="simpleChar"><span class="annot"><span class="annottext">simpleChar :: Char -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#simpleChar"><span class="hs-identifier hs-var hs-var">simpleChar</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">BaseKey -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#simpleKey"><span class="hs-identifier hs-var">simpleKey</span></a></span><span> </span><span class="annot"><span class="annottext">(BaseKey -&gt; Key) -&gt; (Char -&gt; BaseKey) -&gt; Char -&gt; Key
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">Char -&gt; BaseKey
</span><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-var">KeyChar</span></a></span><span>
</span><span id="line-89"></span><span id="metaChar"><span class="annot"><span class="annottext">metaChar :: Char -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#metaChar"><span class="hs-identifier hs-var hs-var">metaChar</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Key -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#metaKey"><span class="hs-identifier hs-var">metaKey</span></a></span><span> </span><span class="annot"><span class="annottext">(Key -&gt; Key) -&gt; (Char -&gt; Key) -&gt; Char -&gt; Key
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">Char -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#simpleChar"><span class="hs-identifier hs-var">simpleChar</span></a></span><span>
</span><span id="line-90"></span><span>
</span><span id="line-91"></span><span id="ctrlChar"><span class="annot"><span class="annottext">ctrlChar :: Char -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#ctrlChar"><span class="hs-identifier hs-var hs-var">ctrlChar</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Char -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#simpleChar"><span class="hs-identifier hs-var">simpleChar</span></a></span><span> </span><span class="annot"><span class="annottext">(Char -&gt; Key) -&gt; (Char -&gt; Char) -&gt; Char -&gt; Key
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">Char -&gt; Char
</span><a href="System.Console.Haskeline.Key.html#setControlBits"><span class="hs-identifier hs-var">setControlBits</span></a></span><span>
</span><span id="line-92"></span><span>
</span><span id="line-93"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#setControlBits"><span class="hs-identifier hs-type">setControlBits</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Char</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Char</span></span><span>
</span><span id="line-94"></span><span id="setControlBits"><span class="annot"><span class="annottext">setControlBits :: Char -&gt; Char
</span><a href="System.Console.Haskeline.Key.html#setControlBits"><span class="hs-identifier hs-var hs-var">setControlBits</span></a></span></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'?'</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; Char
forall a. Enum a =&gt; Int -&gt; a
</span><a href="../../base/src/GHC.Enum.html#toEnum"><span class="hs-identifier hs-var">toEnum</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">127</span></span><span>
</span><span id="line-95"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#setControlBits"><span class="hs-identifier hs-var">setControlBits</span></a></span><span> </span><span id="local-6989586621679091105"><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091105"><span class="hs-identifier hs-var">c</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; Char
forall a. Enum a =&gt; Int -&gt; a
</span><a href="../../base/src/GHC.Enum.html#toEnum"><span class="hs-identifier hs-var">toEnum</span></a></span><span> </span><span class="annot"><span class="annottext">(Int -&gt; Char) -&gt; Int -&gt; Char
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">Char -&gt; Int
forall a. Enum a =&gt; a -&gt; Int
</span><a href="../../base/src/GHC.Enum.html#fromEnum"><span class="hs-identifier hs-var">fromEnum</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091105"><span class="hs-identifier hs-var">c</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Int
forall a. Bits a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/Data.Bits.html#.%26."><span class="hs-operator hs-var">.&amp;.</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int
forall a. Bits a =&gt; a -&gt; a
</span><a href="../../base/src/Data.Bits.html#complement"><span class="hs-identifier hs-var">complement</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="System.Console.Haskeline.Key.html#ctrlBits"><span class="hs-identifier hs-var">ctrlBits</span></a></span><span>
</span><span id="line-96"></span><span>
</span><span id="line-97"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#ctrlBits"><span class="hs-identifier hs-type">ctrlBits</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Int</span></span><span>
</span><span id="line-98"></span><span id="ctrlBits"><span class="annot"><span class="annottext">ctrlBits :: Int
</span><a href="System.Console.Haskeline.Key.html#ctrlBits"><span class="hs-identifier hs-var hs-var">ctrlBits</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int
forall a. Bits a =&gt; Int -&gt; a
</span><a href="../../base/src/Data.Bits.html#bit"><span class="hs-identifier hs-var">bit</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">5</span></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Int
forall a. Bits a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/Data.Bits.html#.%7C."><span class="hs-operator hs-var">.|.</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int
forall a. Bits a =&gt; Int -&gt; a
</span><a href="../../base/src/Data.Bits.html#bit"><span class="hs-identifier hs-var">bit</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">6</span></span><span>
</span><span id="line-99"></span><span>
</span><span id="line-100"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#specialKeys"><span class="hs-identifier hs-type">specialKeys</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span class="hs-special">,</span><span class="annot"><a href="System.Console.Haskeline.Key.html#BaseKey"><span class="hs-identifier hs-type">BaseKey</span></a></span><span class="hs-special">)</span><span class="hs-special">]</span><span>
</span><span id="line-101"></span><span id="specialKeys"><span class="annot"><span class="annottext">specialKeys :: [([Char], BaseKey)]
</span><a href="System.Console.Haskeline.Key.html#specialKeys"><span class="hs-identifier hs-var hs-var">specialKeys</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;left&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#LeftKey"><span class="hs-identifier hs-var">LeftKey</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-102"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;right&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#RightKey"><span class="hs-identifier hs-var">RightKey</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-103"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;down&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#DownKey"><span class="hs-identifier hs-var">DownKey</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-104"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;up&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#UpKey"><span class="hs-identifier hs-var">UpKey</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-105"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;killline&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#KillLine"><span class="hs-identifier hs-var">KillLine</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-106"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;home&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#Home"><span class="hs-identifier hs-var">Home</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-107"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;end&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#End"><span class="hs-identifier hs-var">End</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-108"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;pagedown&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#PageDown"><span class="hs-identifier hs-var">PageDown</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-109"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;pageup&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#PageUp"><span class="hs-identifier hs-var">PageUp</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-110"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;backspace&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#Backspace"><span class="hs-identifier hs-var">Backspace</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-111"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;delete&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#Delete"><span class="hs-identifier hs-var">Delete</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-112"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;return&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">Char -&gt; BaseKey
</span><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-var">KeyChar</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'\n'</span></span><span class="hs-special">)</span><span>
</span><span id="line-113"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;enter&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">Char -&gt; BaseKey
</span><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-var">KeyChar</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'\n'</span></span><span class="hs-special">)</span><span>
</span><span id="line-114"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;tab&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">Char -&gt; BaseKey
</span><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-var">KeyChar</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'\t'</span></span><span class="hs-special">)</span><span>
</span><span id="line-115"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;esc&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">Char -&gt; BaseKey
</span><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-var">KeyChar</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'\ESC'</span></span><span class="hs-special">)</span><span>
</span><span id="line-116"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;escape&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">Char -&gt; BaseKey
</span><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-var">KeyChar</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'\ESC'</span></span><span class="hs-special">)</span><span>
</span><span id="line-117"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;reversesearchhistory&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#SearchReverse"><span class="hs-identifier hs-var">SearchReverse</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-118"></span><span>              </span><span class="hs-special">,</span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;forwardsearchhistory&quot;</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">BaseKey
</span><a href="System.Console.Haskeline.Key.html#SearchForward"><span class="hs-identifier hs-var">SearchForward</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-119"></span><span>              </span><span class="hs-special">]</span><span>
</span><span id="line-120"></span><span>
</span><span id="line-121"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#parseModifiers"><span class="hs-identifier hs-type">parseModifiers</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#BaseKey"><span class="hs-identifier hs-type">BaseKey</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span>
</span><span id="line-122"></span><span id="parseModifiers"><span class="annot"><span class="annottext">parseModifiers :: [[Char]] -&gt; BaseKey -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#parseModifiers"><span class="hs-identifier hs-var hs-var">parseModifiers</span></a></span></span><span> </span><span id="local-6989586621679091099"><span class="annot"><span class="annottext">[[Char]]
</span><a href="#local-6989586621679091099"><span class="hs-identifier hs-var">strs</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Modifier -&gt; BaseKey -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-var">Key</span></a></span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091098"><span class="hs-identifier hs-var">mods</span></a></span><span>
</span><span id="line-123"></span><span>    </span><span class="hs-keyword">where</span><span> </span><span id="local-6989586621679091098"><span class="annot"><span class="annottext">mods :: Modifier
</span><a href="#local-6989586621679091098"><span class="hs-identifier hs-var hs-var">mods</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">((Modifier -&gt; Modifier)
 -&gt; (Modifier -&gt; Modifier) -&gt; Modifier -&gt; Modifier)
-&gt; [Modifier -&gt; Modifier] -&gt; Modifier -&gt; Modifier
forall (t :: * -&gt; *) a. Foldable t =&gt; (a -&gt; a -&gt; a) -&gt; t a -&gt; a
</span><a href="../../base/src/Data.Foldable.html#foldl1"><span class="hs-identifier hs-var">foldl1</span></a></span><span> </span><span class="annot"><span class="annottext">(Modifier -&gt; Modifier)
-&gt; (Modifier -&gt; Modifier) -&gt; Modifier -&gt; Modifier
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">(.)</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">([Char] -&gt; Modifier -&gt; Modifier)
-&gt; [[Char]] -&gt; [Modifier -&gt; Modifier]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">[Char] -&gt; Modifier -&gt; Modifier
</span><a href="System.Console.Haskeline.Key.html#parseModifier"><span class="hs-identifier hs-var">parseModifier</span></a></span><span> </span><span class="annot"><span class="annottext">[[Char]]
</span><a href="#local-6989586621679091099"><span class="hs-identifier hs-var">strs</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="System.Console.Haskeline.Key.html#noModifier"><span class="hs-identifier hs-var">noModifier</span></a></span><span>
</span><span id="line-124"></span><span>
</span><span id="line-125"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#parseModifier"><span class="hs-identifier hs-type">parseModifier</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="System.Console.Haskeline.Key.html#Modifier"><span class="hs-identifier hs-type">Modifier</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Modifier"><span class="hs-identifier hs-type">Modifier</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-126"></span><span id="parseModifier"><span class="annot"><span class="annottext">parseModifier :: [Char] -&gt; Modifier -&gt; Modifier
</span><a href="System.Console.Haskeline.Key.html#parseModifier"><span class="hs-identifier hs-var hs-var">parseModifier</span></a></span></span><span> </span><span id="local-6989586621679091093"><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091093"><span class="hs-identifier hs-var">str</span></a></span></span><span> </span><span id="local-6989586621679091092"><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091092"><span class="hs-identifier hs-var">m</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">(Char -&gt; Char) -&gt; ShowS
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">Char -&gt; Char
</span><a href="../../base/src/GHC.Unicode.html#toLower"><span class="hs-identifier hs-var">toLower</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091093"><span class="hs-identifier hs-var">str</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-127"></span><span>    </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;ctrl&quot;</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091092"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="hs-special">{</span><span class="annot"><span class="annottext">hasControl :: Bool
</span><a href="System.Console.Haskeline.Key.html#hasControl"><span class="hs-identifier hs-var">hasControl</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span class="hs-special">}</span><span>
</span><span id="line-128"></span><span>    </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;control&quot;</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091092"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="hs-special">{</span><span class="annot"><span class="annottext">hasControl :: Bool
</span><a href="System.Console.Haskeline.Key.html#hasControl"><span class="hs-identifier hs-var">hasControl</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span class="hs-special">}</span><span>
</span><span id="line-129"></span><span>    </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;meta&quot;</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091092"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="hs-special">{</span><span class="annot"><span class="annottext">hasMeta :: Bool
</span><a href="System.Console.Haskeline.Key.html#hasMeta"><span class="hs-identifier hs-var">hasMeta</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span class="hs-special">}</span><span>
</span><span id="line-130"></span><span>    </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;shift&quot;</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091092"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="hs-special">{</span><span class="annot"><span class="annottext">hasShift :: Bool
</span><a href="System.Console.Haskeline.Key.html#hasShift"><span class="hs-identifier hs-var">hasShift</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span class="hs-special">}</span><span>
</span><span id="line-131"></span><span>    </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091092"><span class="hs-identifier hs-var">m</span></a></span><span>
</span><span id="line-132"></span><span>
</span><span id="line-133"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#breakAtDashes"><span class="hs-identifier hs-type">breakAtDashes</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-134"></span><span id="breakAtDashes"><span class="annot"><span class="annottext">breakAtDashes :: [Char] -&gt; [[Char]]
</span><a href="System.Console.Haskeline.Key.html#breakAtDashes"><span class="hs-identifier hs-var hs-var">breakAtDashes</span></a></span></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;&quot;</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span>
</span><span id="line-135"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#breakAtDashes"><span class="hs-identifier hs-var">breakAtDashes</span></a></span><span> </span><span id="local-6989586621679091089"><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091089"><span class="hs-identifier hs-var">str</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">(Char -&gt; Bool) -&gt; [Char] -&gt; ([Char], [Char])
forall a. (a -&gt; Bool) -&gt; [a] -&gt; ([a], [a])
</span><a href="../../base/src/GHC.List.html#break"><span class="hs-identifier hs-var">break</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Char -&gt; Char -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'-'</span></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091089"><span class="hs-identifier hs-var">str</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-136"></span><span>    </span><span class="hs-special">(</span><span id="local-6989586621679091087"><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091087"><span class="hs-identifier hs-var">xs</span></a></span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'-'</span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span id="local-6989586621679091086"><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091086"><span class="hs-identifier hs-var">rest</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091087"><span class="hs-identifier hs-var">xs</span></a></span><span> </span><span class="annot"><span class="annottext">[Char] -&gt; [[Char]] -&gt; [[Char]]
forall a. a -&gt; [a] -&gt; [a]
</span><span class="hs-glyph hs-var">:</span></span><span> </span><span class="annot"><span class="annottext">[Char] -&gt; [[Char]]
</span><a href="System.Console.Haskeline.Key.html#breakAtDashes"><span class="hs-identifier hs-var">breakAtDashes</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091086"><span class="hs-identifier hs-var">rest</span></a></span><span>
</span><span id="line-137"></span><span>    </span><span class="hs-special">(</span><span id="local-6989586621679091085"><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091085"><span class="hs-identifier hs-var">xs</span></a></span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091085"><span class="hs-identifier hs-var">xs</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-138"></span><span>
</span><span id="line-139"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#parseKey"><span class="hs-identifier hs-type">parseKey</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span>
</span><span id="line-140"></span><span id="parseKey"><span class="annot"><span class="annottext">parseKey :: [Char] -&gt; Maybe Key
</span><a href="System.Console.Haskeline.Key.html#parseKey"><span class="hs-identifier hs-var hs-var">parseKey</span></a></span></span><span> </span><span id="local-6989586621679091084"><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091084"><span class="hs-identifier hs-var">str</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(Key -&gt; Key) -&gt; Maybe Key -&gt; Maybe Key
forall (f :: * -&gt; *) a b. Functor f =&gt; (a -&gt; b) -&gt; f a -&gt; f b
</span><a href="../../base/src/GHC.Base.html#fmap"><span class="hs-identifier hs-var">fmap</span></a></span><span> </span><span class="annot"><span class="annottext">Key -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#canonicalizeKey"><span class="hs-identifier hs-var">canonicalizeKey</span></a></span><span> </span><span class="annot"><span class="annottext">(Maybe Key -&gt; Maybe Key) -&gt; Maybe Key -&gt; Maybe Key
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span>
</span><span id="line-141"></span><span>    </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">[[Char]] -&gt; [[Char]]
forall a. [a] -&gt; [a]
</span><a href="../../base/src/GHC.List.html#reverse"><span class="hs-identifier hs-var">reverse</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char] -&gt; [[Char]]
</span><a href="System.Console.Haskeline.Key.html#breakAtDashes"><span class="hs-identifier hs-var">breakAtDashes</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091084"><span class="hs-identifier hs-var">str</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-142"></span><span>        </span><span class="hs-special">[</span><span id="local-6989586621679091081"><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091081"><span class="hs-identifier hs-var">ks</span></a></span></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">(BaseKey -&gt; Key) -&gt; Maybe BaseKey -&gt; Maybe Key
forall (m :: * -&gt; *) a1 r. Monad m =&gt; (a1 -&gt; r) -&gt; m a1 -&gt; m r
</span><a href="../../base/src/GHC.Base.html#liftM"><span class="hs-identifier hs-var">liftM</span></a></span><span> </span><span class="annot"><span class="annottext">BaseKey -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#simpleKey"><span class="hs-identifier hs-var">simpleKey</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char] -&gt; Maybe BaseKey
</span><a href="System.Console.Haskeline.Key.html#parseBaseKey"><span class="hs-identifier hs-var">parseBaseKey</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091081"><span class="hs-identifier hs-var">ks</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-143"></span><span>        </span><span id="local-6989586621679091078"><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091078"><span class="hs-identifier hs-var">ks</span></a></span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span id="local-6989586621679091077"><span class="annot"><span class="annottext">[[Char]]
</span><a href="#local-6989586621679091077"><span class="hs-identifier hs-var">ms</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">(BaseKey -&gt; Key) -&gt; Maybe BaseKey -&gt; Maybe Key
forall (m :: * -&gt; *) a1 r. Monad m =&gt; (a1 -&gt; r) -&gt; m a1 -&gt; m r
</span><a href="../../base/src/GHC.Base.html#liftM"><span class="hs-identifier hs-var">liftM</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">[[Char]] -&gt; BaseKey -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#parseModifiers"><span class="hs-identifier hs-var">parseModifiers</span></a></span><span> </span><span class="annot"><span class="annottext">[[Char]]
</span><a href="#local-6989586621679091077"><span class="hs-identifier hs-var">ms</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">[Char] -&gt; Maybe BaseKey
</span><a href="System.Console.Haskeline.Key.html#parseBaseKey"><span class="hs-identifier hs-var">parseBaseKey</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091078"><span class="hs-identifier hs-var">ks</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-144"></span><span>        </span><span class="hs-special">[</span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Maybe Key
forall a. Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span>
</span><span id="line-145"></span><span>
</span><span id="line-146"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#parseBaseKey"><span class="hs-identifier hs-type">parseBaseKey</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../base/src/GHC.Base.html#String"><span class="hs-identifier hs-type">String</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#BaseKey"><span class="hs-identifier hs-type">BaseKey</span></a></span><span>
</span><span id="line-147"></span><span id="parseBaseKey"><span class="annot"><span class="annottext">parseBaseKey :: [Char] -&gt; Maybe BaseKey
</span><a href="System.Console.Haskeline.Key.html#parseBaseKey"><span class="hs-identifier hs-var hs-var">parseBaseKey</span></a></span></span><span> </span><span id="local-6989586621679091076"><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091076"><span class="hs-identifier hs-var">ks</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Char] -&gt; [([Char], BaseKey)] -&gt; Maybe BaseKey
forall a b. Eq a =&gt; a -&gt; [(a, b)] -&gt; Maybe b
</span><a href="../../base/src/GHC.List.html#lookup"><span class="hs-identifier hs-var">lookup</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">(Char -&gt; Char) -&gt; ShowS
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">Char -&gt; Char
</span><a href="../../base/src/GHC.Unicode.html#toLower"><span class="hs-identifier hs-var">toLower</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091076"><span class="hs-identifier hs-var">ks</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">[([Char], BaseKey)]
</span><a href="System.Console.Haskeline.Key.html#specialKeys"><span class="hs-identifier hs-var">specialKeys</span></a></span><span>
</span><span id="line-148"></span><span>                </span><span class="annot"><span class="annottext">Maybe BaseKey -&gt; Maybe BaseKey -&gt; Maybe BaseKey
forall (m :: * -&gt; *) a. MonadPlus m =&gt; m a -&gt; m a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#mplus"><span class="hs-operator hs-var">`mplus`</span></a></span><span> </span><span class="annot"><span class="annottext">[Char] -&gt; Maybe BaseKey
</span><a href="#local-6989586621679091073"><span class="hs-identifier hs-var">parseFunctionKey</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091076"><span class="hs-identifier hs-var">ks</span></a></span><span>
</span><span id="line-149"></span><span>                </span><span class="annot"><span class="annottext">Maybe BaseKey -&gt; Maybe BaseKey -&gt; Maybe BaseKey
forall (m :: * -&gt; *) a. MonadPlus m =&gt; m a -&gt; m a -&gt; m a
</span><a href="../../base/src/GHC.Base.html#mplus"><span class="hs-operator hs-var">`mplus`</span></a></span><span> </span><span class="annot"><span class="annottext">[Char] -&gt; Maybe BaseKey
</span><a href="#local-6989586621679091072"><span class="hs-identifier hs-var">parseKeyChar</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091076"><span class="hs-identifier hs-var">ks</span></a></span><span>
</span><span id="line-150"></span><span>    </span><span class="hs-keyword">where</span><span>
</span><span id="line-151"></span><span>        </span><span id="local-6989586621679091072"><span class="annot"><span class="annottext">parseKeyChar :: [Char] -&gt; Maybe BaseKey
</span><a href="#local-6989586621679091072"><span class="hs-identifier hs-var hs-var">parseKeyChar</span></a></span></span><span> </span><span class="hs-special">[</span><span id="local-6989586621679091071"><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091071"><span class="hs-identifier hs-var">c</span></a></span></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Char -&gt; Bool
</span><a href="../../base/src/GHC.Unicode.html#isPrint"><span class="hs-identifier hs-var">isPrint</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091071"><span class="hs-identifier hs-var">c</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">BaseKey -&gt; Maybe BaseKey
forall a. a -&gt; Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-var">Just</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Char -&gt; BaseKey
</span><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-var">KeyChar</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091071"><span class="hs-identifier hs-var">c</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-152"></span><span>        </span><span class="annot"><a href="#local-6989586621679091072"><span class="hs-identifier hs-var">parseKeyChar</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Maybe BaseKey
forall a. Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span>
</span><span id="line-153"></span><span>
</span><span id="line-154"></span><span>        </span><span id="local-6989586621679091073"><span class="annot"><span class="annottext">parseFunctionKey :: [Char] -&gt; Maybe BaseKey
</span><a href="#local-6989586621679091073"><span class="hs-identifier hs-var hs-var">parseFunctionKey</span></a></span></span><span> </span><span class="hs-special">(</span><span id="local-6989586621679091066"><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091066"><span class="hs-identifier hs-var">f</span></a></span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span id="local-6989586621679091065"><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091065"><span class="hs-identifier hs-var">ns</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091066"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="annot"><span class="annottext">Char -&gt; [Char] -&gt; Bool
forall (t :: * -&gt; *) a. (Foldable t, Eq a) =&gt; a -&gt; t a -&gt; Bool
</span><a href="../../base/src/Data.Foldable.html#elem"><span class="hs-operator hs-var">`elem`</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;fF&quot;</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">ReadS Int
forall a. Read a =&gt; ReadS a
</span><a href="../../base/src/Text.Read.html#reads"><span class="hs-identifier hs-var">reads</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><a href="#local-6989586621679091065"><span class="hs-identifier hs-var">ns</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-155"></span><span>            </span><span class="hs-special">[</span><span class="hs-special">(</span><span id="local-6989586621679091062"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621679091062"><span class="hs-identifier hs-var">n</span></a></span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-string">&quot;&quot;</span></span><span class="hs-special">)</span><span class="hs-special">]</span><span>    </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">BaseKey -&gt; Maybe BaseKey
forall a. a -&gt; Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-var">Just</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Int -&gt; BaseKey
</span><a href="System.Console.Haskeline.Key.html#FunKey"><span class="hs-identifier hs-var">FunKey</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621679091062"><span class="hs-identifier hs-var">n</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-156"></span><span>            </span><span class="annot"><span class="annottext">[(Int, [Char])]
</span><span class="hs-identifier">_</span></span><span>           </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Maybe BaseKey
forall a. Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span>
</span><span id="line-157"></span><span>        </span><span class="annot"><a href="#local-6989586621679091073"><span class="hs-identifier hs-var">parseFunctionKey</span></a></span><span> </span><span class="annot"><span class="annottext">[Char]
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Maybe BaseKey
forall a. Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span>
</span><span id="line-158"></span><span>
</span><span id="line-159"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#canonicalizeKey"><span class="hs-identifier hs-type">canonicalizeKey</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span>
</span><span id="line-160"></span><span id="canonicalizeKey"><span class="annot"><span class="annottext">canonicalizeKey :: Key -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#canonicalizeKey"><span class="hs-identifier hs-var hs-var">canonicalizeKey</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span> </span><span id="local-6989586621679091061"><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091061"><span class="hs-identifier hs-var">m</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-type">KeyChar</span></a></span><span> </span><span id="local-6989586621679091060"><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091060"><span class="hs-identifier hs-var">c</span></a></span></span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-161"></span><span>    </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Modifier -&gt; Bool
</span><a href="System.Console.Haskeline.Key.html#hasControl"><span class="hs-identifier hs-var hs-var">hasControl</span></a></span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091061"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Modifier -&gt; BaseKey -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-var">Key</span></a></span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091061"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="hs-special">{</span><span class="annot"><span class="annottext">hasControl :: Bool
</span><a href="System.Console.Haskeline.Key.html#hasControl"><span class="hs-identifier hs-var">hasControl</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span class="hs-special">}</span><span>
</span><span id="line-162"></span><span>                        </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Char -&gt; BaseKey
</span><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-var">KeyChar</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Char -&gt; Char
</span><a href="System.Console.Haskeline.Key.html#setControlBits"><span class="hs-identifier hs-var">setControlBits</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091060"><span class="hs-identifier hs-var">c</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-163"></span><span>    </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Modifier -&gt; Bool
</span><a href="System.Console.Haskeline.Key.html#hasShift"><span class="hs-identifier hs-var hs-var">hasShift</span></a></span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091061"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Modifier -&gt; BaseKey -&gt; Key
</span><a href="System.Console.Haskeline.Key.html#Key"><span class="hs-identifier hs-var">Key</span></a></span><span> </span><span class="annot"><span class="annottext">Modifier
</span><a href="#local-6989586621679091061"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="hs-special">{</span><span class="annot"><span class="annottext">hasShift :: Bool
</span><a href="System.Console.Haskeline.Key.html#hasShift"><span class="hs-identifier hs-var">hasShift</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span class="hs-special">}</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Char -&gt; BaseKey
</span><a href="System.Console.Haskeline.Key.html#KeyChar"><span class="hs-identifier hs-var">KeyChar</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Char -&gt; Char
</span><a href="../../base/src/GHC.Unicode.html#toUpper"><span class="hs-identifier hs-var">toUpper</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621679091060"><span class="hs-identifier hs-var">c</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-164"></span><span class="annot"><a href="System.Console.Haskeline.Key.html#canonicalizeKey"><span class="hs-identifier hs-var">canonicalizeKey</span></a></span><span> </span><span id="local-6989586621679091058"><span class="annot"><span class="annottext">Key
</span><a href="#local-6989586621679091058"><span class="hs-identifier hs-var">k</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Key
</span><a href="#local-6989586621679091058"><span class="hs-identifier hs-var">k</span></a></span><span>
</span><span id="line-165"></span></pre></body></html>